package com.eastcom.common.db;

import java.util.ArrayList;
import java.util.List;

public class ObjRelationMapping {

	private String tableName;
	
	private Class entityClass;
	
	private List<ColumnRelation> columnReflects;

	public List<ColumnRelation> getColumnReflects() {
		return columnReflects;
	}

	public void setColumnReflects(List<ColumnRelation> columnReflects) {
		this.columnReflects = columnReflects;
	}

	public Class getEntityClass() {
		return entityClass;
	}

	public void setEntityClass(Class entityClass) {
		this.entityClass = entityClass;
	}
	
	public void addColumnRelation(ColumnRelation columnRelation){
		if(columnRelation==null)
			return;
		
		if(columnReflects==null)
			columnReflects=new ArrayList<ColumnRelation>();
		
		columnReflects.add(columnRelation);
	}

	public String getTableName() {
		return tableName;
	}

	public void setTableName(String tableName) {
		this.tableName = tableName;
	}
	
}
